import request from 'umi-request';

export async function queryChannel() {
  return request('/api/v1/device/channel');
}
export async function liveStart(deviceId,channelId) {
  return request(`/api/v1/device/live/start/${deviceId}/${channelId}`);
}
export async function livEnd(deviceId,channelId) {
  return request(`/api/v1/device/live/end/${deviceId}/${channelId}`);
}

export async function playbackStart(deviceId,channelId,startTime,endTime) {
  return request(`/api/v1/device/playback/start/${deviceId}/${channelId}?startTime=${startTime}&endTime=${endTime}`);
}
